home *** CD-ROM | disk | FTP | other *** search
/ Delphi 5 for Professionals / DELPHI5.iso / AddOns / Components / InstallMaster 7.03 / Devfulldemo.exe / file0207.bin < prev    next >
Encoding:
Text File  |  1999-04-26  |  2.9 KB  |  109 lines

  1. Document Type: WSE
  2. item: Global
  3.   Version=6.0
  4.   Title=Division
  5.   Flags=00000100
  6.   Split=1420
  7.   Languages=65 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
  8.   Copy Default=1
  9.   Japanese Font Name=MS Gothic
  10.   Japanese Font Size=10
  11.   Start Gradient=0 0 255
  12.   End Gradient=0 0 0
  13.   Windows Flags=00000100000000000010110000001000
  14.   Message Font=MS Sans Serif
  15.   Font Size=8
  16.   Disk Filename=SETUP
  17.   Patch Flags=0000000000000001
  18.   Patch Threshold=85
  19.   Patch Memory=4000
  20.   FTP Cluster Size=20
  21. end
  22. item: Remark
  23.   Text=The Wise 6.0 sample script shows how to do a simple division function with Wise's expression parser.
  24. end
  25. item: Remark
  26. end
  27. item: Remark
  28.   Text=These middle lines of code are devoted to getting the numbers to be divided, 
  29. end
  30. item: Remark
  31.   Text=            and to make sure that the divisor is not zero.
  32. end
  33. item: Remark
  34. end
  35. item: Set Variable
  36.   Variable=NUMBER2
  37.   Value=0
  38. end
  39. item: Prompt for Text
  40.   Window Title=Parser Division Test
  41.   Prompt Title=Please enter a number.
  42.   Variable=NUMBER
  43. end
  44. item: If/While Statement
  45.   Variable=NUMBER2
  46.   Value=0
  47.   Flags=00010000
  48. end
  49. item: Prompt for Text
  50.   Window Title=Parser Divisor Test
  51.   Prompt Title=Please enter a second number.
  52.   Variable=NUMBER2
  53. end
  54. item: If/While Statement
  55.   Variable=NUMBER2
  56.   Value=0
  57. end
  58. item: Display Message
  59.   Title=Invalid Number
  60.   Text=You can not divide a number by zero. It will cause your application to crash.
  61. end
  62. item: End Block
  63. end
  64. item: End Block
  65. end
  66. item: Remark
  67. end
  68. item: Remark
  69.   Text=There are two ways to use the expression parser. The first is with a set variable command, using the "Evaluate expression" option.
  70. end
  71. item: Remark
  72.   Text=When creating an expression, you do not have to use the percent signs to define the variables.
  73. end
  74. item: Set Variable
  75.   Variable=ANSWER
  76.   Value=NUMBER / NUMBER2
  77.   Flags=00100000
  78. end
  79. item: Display Message
  80.   Title=Expression Parser - Division Test 1.
  81.   Text=This Display message shows the set variable command in conjunction with the Expression parser.
  82.   Text=
  83.   Text= %Number% / %Number2% = %Answer%
  84.   Text=
  85.   Text=(Note: When dividing, the parser will always return an integer value, rounded down.              ex. 10/3 = 3. 10/4 = 2.)
  86. end
  87. item: Remark
  88. end
  89. item: Remark
  90.   Text=This is the second way, using an If statement, and the "Expression true" option.
  91. end
  92. item: Remark
  93.   Text=You can also use the command options such as <, >, >=, <=, and, or, not, and <>.
  94. end
  95. item: If/While Statement
  96.   Value=ANSWER = NUMBER / NUMBER2
  97.   Flags=00001101
  98. end
  99. item: Display Message
  100.   Title=Expression Parser - Division Test 2.
  101.   Text=This Display message shows the If Statement in conjunction with the Expression parser. If the result was not true, this message would not be displayed.
  102.   Text=
  103.   Text=Yes,  %Number% / %Number2% = %Answer%
  104.   Text=
  105.   Text=(Note: When dividing, the parser will always return an integer value rounded down.            ex. 10/3 = 3. 10/4 = 2.)
  106. end
  107. item: End Block
  108. end
  109.